20504b354fae80fc754f3ac3d563c544bd70c965,src/freenet/client/async/SplitFileInserterSegment.java,MySendableRequestSender,send,#NodeClientCore#RequestScheduler#ClientContext#ChosenBlock#,1418

Before Change


					num = block.blockNum;
					if(block.persistent) {
						req.setGeneratedKey(key);
					} else if(!req.localRequestOnly) {
						context.mainExecutor.execute(new Runnable() {

							public void run() {
								seg.onEncode(num, key, null, context);
							}

						}, "Got URI");

					}
					if(req.localRequestOnly)
						try {
							core.node.store(b, false, req.canWriteClientCache, true, false);
						} catch (KeyCollisionException e) {
							throw new LowLevelPutException(LowLevelPutException.COLLISION);
						}
					else
						core.realPut(b, req.canWriteClientCache, req.forkOnCacheable, Node.PREFER_INSERT_DEFAULT, Node.IGNORE_LOW_BACKOFF_DEFAULT);
				} catch (LowLevelPutException e) {
					req.onFailure(e, context);
					if(SplitFileInserterSegment.logMINOR) Logger.minor(this, "Request failed for "+e);
					return true;
				}
				if(SplitFileInserterSegment.logMINOR) Logger.minor(this, "Request succeeded");
				if(req.localRequestOnly) {
					// Must run on-thread or we will have exploding threads.
					// Plus must run before onInsertSuccess().
					if(!block.persistent)
						seg.onEncode(num, key, null, context);
					req.onInsertSuccess(context);
				} else if(!block.persistent) {
					// Must run after onEncode.
					context.mainExecutor.execute(new Runnable() {

						public void run() {
							// Make absolutely sure even if we run the two jobs out of order.
							// Overhead for double-checking should be very low.
							seg.onEncode(num, key, null, context);
							req.onInsertSuccess(context);
						}

					}, "Succeeded");
				} else {
					req.onInsertSuccess(context);
				}
				return true;
			}

After Change


					return true;
				}
				if(SplitFileInserterSegment.logMINOR) Logger.minor(this, "Request succeeded");
				req.onInsertSuccess(context);
				return true;
			}